package com.xidian.zhiancloud.controller.ypp.processmanage;


import com.xidian.zhiancloud.dto.ResultDTO;
import com.xidian.zhiancloud.enums.GeneralResponseEnums;
import com.xidian.zhiancloud.service.ypp.processmanage.DangerousOperationDelayApprovalService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

//危险作业延期审批
@RestController
@RequestMapping("/dangerousoperationdelayapproval")
public class DangerousOperationDelayApprovalController {
    @Autowired
    private DangerousOperationDelayApprovalService dangerousOperationDelayApprovalService;

    //查所有
    @GetMapping("/getById")
    public ResultDTO getById(@RequestParam("classify") String classify) {
        return ResultDTO.successOf(dangerousOperationDelayApprovalService.getById(classify), GeneralResponseEnums.SUCCESS);
    }

    //查看

    //编辑

    //删除
    @DeleteMapping("/deleteById")
    public ResultDTO deleteById(@RequestParam("id") Long id){
        dangerousOperationDelayApprovalService.deleteById(id);
        return ResultDTO.successOf(GeneralResponseEnums.SUCCESS);
    }
}
